package common.adventurecard;

import java.io.Serializable;
import java.util.Comparator;

import common.AdvCard;

public class AdvCardComparator implements Comparator<AdvCard>, Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@Override
	public int compare(final AdvCard adv1, final AdvCard adv2) {
		if (adv1.getPriority() < adv2.getPriority()) {
			return -1;
		} else if (adv1.getPriority() > adv2.getPriority()) {
			return 1;
		} else {
			return 0;
		}
	}
}
